1 /* 2 3 Boost Software License - Version 1.0 - August 17th, 2003 4 5 Permission is hereby granted, free of charge, to any person or organization 6 obtaining a copy of the software and accompanying documentation covered by 7 this license (the "Software") to use, reproduce, display, distribute, 8 execute, and transmit the Software, and to prepare derivative works of the 9 Software, and to permit third-parties to whom the Software is furnished to 10 do so, all subject to the following: 11 12 The copyright notices in the Software and this entire statement, including 13 the above license grant, this restriction and the following disclaimer, 14 must be included in all copies of the Software, in whole or in part, and 15 all derivative works of the Software, unless such copies or derivative 16 works are solely in the form of machine-executable object code generated by 17 a source language processor. 18 19 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 20 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 21 FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT 22 SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE 23 FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, 24 ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 25 DEALINGS IN THE SOFTWARE. 26 27 */ 28 29 module derelict.glib.gtimezone; 30 31 import derelict.glib.gtypes; 32 import derelict.glib.glibconfig; 33 import core.stdc.config; 34 35 extern (C): 36 37 alias _GTimeZone GTimeZone; 38 alias _Anonymous_0 GTimeType; 39 40 enum _Anonymous_0 41 { 42 G_TIME_TYPE_STANDARD = 0, 43 G_TIME_TYPE_DAYLIGHT = 1, 44 G_TIME_TYPE_UNIVERSAL = 2 45 } 46 47 struct _GTimeZone; 48 49 50 version(Derelict_Link_Static) 51 { 52 extern( C ) nothrow 53 { 54 GTimeZone* g_time_zone_new(const(gchar)* identifier); 55 GTimeZone* g_time_zone_new_utc(); 56 GTimeZone* g_time_zone_new_local(); 57 GTimeZone* g_time_zone_ref(GTimeZone* tz); 58 void g_time_zone_unref(GTimeZone* tz); 59 gint g_time_zone_find_interval(GTimeZone* tz, GTimeType type, gint64 time_); 60 gint g_time_zone_adjust_time(GTimeZone* tz, GTimeType type, gint64* time_); 61 const(gchar)* g_time_zone_get_abbreviation(GTimeZone* tz, gint interval); 62 gint32 g_time_zone_get_offset(GTimeZone* tz, gint interval); 63 gboolean g_time_zone_is_dst(GTimeZone* tz, gint interval); 64 } 65 } 66 else 67 { 68 extern( C ) nothrow 69 { 70 alias da_g_time_zone_new = GTimeZone* function(const(gchar)* identifier); 71 alias da_g_time_zone_new_utc = GTimeZone* function(); 72 alias da_g_time_zone_new_local = GTimeZone* function(); 73 alias da_g_time_zone_ref = GTimeZone* function(GTimeZone* tz); 74 alias da_g_time_zone_unref = void function(GTimeZone* tz); 75 alias da_g_time_zone_find_interval = gint function(GTimeZone* tz, GTimeType type, gint64 time_); 76 alias da_g_time_zone_adjust_time = gint function(GTimeZone* tz, GTimeType type, gint64* time_); 77 alias da_g_time_zone_get_abbreviation = const(gchar)* function(GTimeZone* tz, gint interval); 78 alias da_g_time_zone_get_offset = gint32 function(GTimeZone* tz, gint interval); 79 alias da_g_time_zone_is_dst = gboolean function(GTimeZone* tz, gint interval); 80 } 81 82 __gshared 83 { 84 da_g_time_zone_new g_time_zone_new; 85 da_g_time_zone_new_utc g_time_zone_new_utc; 86 da_g_time_zone_new_local g_time_zone_new_local; 87 da_g_time_zone_ref g_time_zone_ref; 88 da_g_time_zone_unref g_time_zone_unref; 89 da_g_time_zone_find_interval g_time_zone_find_interval; 90 da_g_time_zone_adjust_time g_time_zone_adjust_time; 91 da_g_time_zone_get_abbreviation g_time_zone_get_abbreviation; 92 da_g_time_zone_get_offset g_time_zone_get_offset; 93 da_g_time_zone_is_dst g_time_zone_is_dst; 94 } 95 }